package org.yuyao.system.service.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.yuyao.system.entity.SysUser;
import org.yuyao.system.mapper.SysUserMapper;
import org.yuyao.system.service.ISysUserService;

import java.util.List;

/**
 * @author yuyao
 * @date 2025-03-11 22:15:05
 * @description TODO
 */
@Service
public class SysUserServiceImpl implements ISysUserService {
   @Autowired
    private SysUserMapper sysUserMapper;
    @Override
    public int insert(SysUser sysUser) {
        return sysUserMapper.insert(sysUser);
    }

    @Override
    public int updateById(SysUser sysUser) {
        return sysUserMapper.updateById(sysUser);
    }

    @Override
    public int deleteById(String id) {
        return sysUserMapper.deleteById(id);
    }

    @Override
    public List<SysUser> selectByQueryList(SysUser sysUser) {
        return sysUserMapper.selectByQueryList(sysUser);
    }

    @Override
    public SysUser selectById(String id) {
        return sysUserMapper.selectById(id);
    }

    @Override
    public SysUser selectByUserName(String userName) {
        return sysUserMapper.selectByUsername(userName);
    }

    @Override
    public SysUser selectByPhone(String phone) {
        return sysUserMapper.selectByPhone(phone);
    }

    @Override
    public SysUser selectByEmail(String email) {
        return sysUserMapper.selectByEmail(email);
    }
}
